import React, { Component } from 'react';
import { NavBar } from 'antd-mobile';
import YwxBackIcon from '../YwxBackIcon/YwxBackIcon';

export default class YwxNavBar extends Component {
    render() {
        return (
            <NavBar mode="dark"
                icon={this.props.noIcon ? <span></span> : <YwxBackIcon />}
                rightContent={this.props.rightContent}
            >{this.props.children}</NavBar>
        );
    }
}